package main
import "fmt"

func main(){
  slice1 := make([]int, 0, 10)
  for i:=0;i<cap(slice1);i++{
	slice1 = slice1[0:i+1]
	slice1[i] = i
	fmt.Printf("The length of slice1 is %d at %d-iteration\n", len(slice1), i)
  }
  // print the slice1
  for i:=0;i<len(slice1);i++{
	fmt.Printf("slice1 at %d is %d\n", i, slice1[i])
  }
}
